from common.emqx.emqx_client import EMQXClient

# 初始化发送客户端
sender = EMQXClient(
    client_id="orangepi_mqprovider",
    broker="192.168.1.42",
    port=8083
)

with sender:
    sender.publish(
        # topic="orangepi_test",
        topic="esp32Conect",
        payload={"type": "temp","value": "31"},
        qos=1
    )